<%@ taglib uri="http://java.sun.com/jsp/jstl/core" prefix="c"%>
<%@ page language="java" contentType="text/html; charset=UTF-8"
  pageEncoding="UTF-8"%>
<div class="navbar navbar-default">
  <div class="navbar-header">
    <a class="navbar-brand" href="#">Project name</a>
  </div>
  <div id="topmenu" class="navbar-collapse collapse">
    <ul id="mainmenu" class="nav navbar-nav">
      <c:forEach var="menu" items="${menuList.menuList}">
        <li id="md-<c:out value="${menu.id}" />"
          <c:if test="${menu.id==mainId}">
              class="active"
            </c:if>><a
          href="javascript:;"><c:out value="${menu.name}" /></a></li>
      </c:forEach>
    </ul>
    <c:forEach var="menu" items="${menuList.menuList}">
      <div id="imd-<c:out value="${menu.id}" />"
        <c:if test="${menu.id!=mainId}"> style="display:none"
        </c:if>>
        <ul>
          <c:forEach var="childmenu" items="${menu.childMenuList}">
            <li><c:choose>
                <c:when test="${childmenu.id==subId}">
                  <c:out value="${childmenu.name}" />
                </c:when>
                <c:otherwise>
                  <a href="<c:out value="${childmenu.url}" />"><c:out
                      value="${childmenu.name}" /></a>
                </c:otherwise>
              </c:choose></li>
          </c:forEach>
        </ul>
      </div>
    </c:forEach>
    <!-- <ul class="nav navbar-nav navbar-right">
      <li><a href="/modifypwd">修改密码</a></li>
      <li><a href="/logout">退出</a></li>
    </ul> -->
  </div>
</div>